LiveCode Motion
Type
library
Summary
LiveCode Motion is a comprehensive animation library for creating fluid, dynamic animations in LiveCode applications.
Description
This library provides powerful tools for creating animations in LiveCode. It supports multiple animation approaches including:
- Direct property animations with customizable easing
- Keyframe-based animations for complex sequences
- Timeline-based animations
- State transitions
- Path-based motion
The library works with numeric values, points, colors, and rectangles, making it suitable for animating position, size, color, opacity and other visual properties of any LiveCode control.
Compatibility and Support
OS
mac
windows
linux
ios
android
Platforms
desktop
mobile
web
Associated Syntax
Property
Name | Summary | Syntax |
---|---|---|
scaleXY | Sets both horizontal and vertical scaling of an object by adjusting width and height together | set the scaleXY of object to <number>[%] |
translateY | Sets the vertical translation of an object by moving it along the Y-axis | set the translateY of object to <number>[%] |
translateX | Sets the horizontal translation of an object by moving it along the X-axis | set the translateX of object to <number>[%] |
scaleY | Sets the vertical scaling of an object by adjusting its height | set the scaleY of object to <number>[%] |
scaleX | Sets the horizontal scaling of an object by adjusting its width | set the scaleX of object to <number>[%] |
Command
Name | Summary | Syntax |
---|---|---|
defineAnimation | Defines a reusable keyframe animation sequence. | defineAnimation <pName>, <pKeyframes>, <pDuration>, <pEasing> |
playAnimation | Resume an animation or all paused or stopped animations | playAnimation [<pAnimationID>] |
deleteAnimation | Deletes a previously defined animation. | deleteAnimation <pName> |
unlockAnimations | Allowing object motions caused with the animate command to be seen. | unlockAnimations |
animateProperty | Change the value of a property of an object in an animated way | animateProperty <pControl>, <pPropertyName>, <pEndValue>, [<pDuration>], [<pEasing> | <pAnimationOptions>] |
stopAnimation | Stop one animation or all animations | stopAnimation [<pAnimationID>] |
updateAnimation | Updates an existing animation definition with new parameters. | updateAnimation <pName>, <pKeyframes>, <pDuration>, <pEasing> |
pauseAnimation | Pause one animation or all animations | pauseAnimation [<pAnimationID>] |
lockAnimations | Temporarily preventing the animations | lockAnimations |
startAnimation | Starts playing an animation instance. | startAnimation <pID> |
Message
Name | Summary | Syntax |
---|---|---|
enterAnimationFrame | This message is sent to the objects before updating the value of each animation. | enterAnimationFrame <pAnimationID> |
startingAnimation | Message fired on the object that the animation is applied to. | startingAnimation <pAnimationID> |
animationDone | Message generated at the end of an animation. | animationDone <pAnimationID> |
failedAnimation | Message generated when an animation fails. | failedAnimation <pErrorMessage> |
exitAnimationFrame | This message is sent to the objects after the value of the animation is updated. | exitAnimationFrame <pAnimationID> |
Function
Name | Summary | Syntax |
---|---|---|
animationDefinitions | Returns a list of all defined animations. | get animationDefinitions() |
getAnimationID | Returns the ID of any active animation for a specific control and property. | get getAnimationID(pControl, pPropertyName) |
createAnimationInstance | Creates an animation instance from a defined animation. | createAnimationInstance(<pTargetControl>, <pAnimationName>, [<pOptions>]) |
easingMethods | List the names of all easing methods. | get easingMethods() |